<?php
namespace app\index\controller;

use \think\Controller;
use \think\facade\Session;

class Base extends  Controller
{
	public function initialize()
	{
		
		if(!Session::has('userinfo'))
		{
			$this->error('当前用户没有登录','index/login/index');

			exit;
		}
		$this->assign('userinfo',session('userinfo')); 
		
	}
}
